package cn.qiyu5522.tk_ems.service.impl;

import cn.qiyu5522.tk_ems.entity.vo.EmployStatisticVO;
import cn.qiyu5522.tk_ems.mapper.EmployStatisticMapper;
import cn.qiyu5522.tk_ems.result.R;
import cn.qiyu5522.tk_ems.service.EmployStatisticService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @ProjectName: tk_ems
 * @Package: cn.qiyu5522.tk_ems.service.impl
 * @ClassName: EmployStatisticServiceImpl
 * @Author: [Toneky]
 * @Date: 2023/3/6 16:37
 * @Version: V1.0
 **/
@Service
public class EmployStatisticServiceImpl extends ServiceImpl<EmployStatisticMapper, EmployStatisticVO> implements EmployStatisticService {
    @Override
    public R majorStatistic() {
        List<EmployStatisticVO> employStatisticVOS = baseMapper.majorStatistic();
        return R.ok().data("majorStatistic",employStatisticVOS);
    }

    @Override
    public R classroomStatistic() {
        List<EmployStatisticVO> classroomStatistic = baseMapper.classroomStatistic();
        return R.ok().data("classroomStatistic",classroomStatistic);
    }

    @Override
    public R jobStatistic() {
        List<EmployStatisticVO> jobStatistic = baseMapper.jobStatistic();
        return R.ok().data("jobStatistic",jobStatistic);
    }

    @Override
    public R companyStatistic() {
        List<EmployStatisticVO> companyStatistic = baseMapper.companyStatistic();
        return R.ok().data("companyStatistic",companyStatistic);
    }
}
